<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="description" content="Medicloud">
        <meta name="author" content="Medicloud Team">
        <link rel="shortcut icon" href="/assets/ico/favicon.png">

        <title>{{title}}</title>

        <!-- Core CSS -->
        <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700,800' rel='stylesheet' type='text/css'>
        <link href="/static/css/bootstrap.css" rel="stylesheet">
        <link href="/static/css/font-awesome.min.css" rel="stylesheet">
        <link href="/static/css/main.css" rel="stylesheet">
        <!-- Custom styles for this template -->
        {% block custom_style %}{% endblock %}
    </head>
    <body>
        <!-- Navbar -->
        <div class="navbar navbar-inverse navbar-fixed-top">
            <div class="container">
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>
                    <a class="navbar-brand sans" href="/">medicloud</a>
                </div>
                <div class="collapse navbar-collapse">
                    <ul class="nav navbar-nav">
                        <li {% if title == "Home" %}class="active"{% endif %}><a href="/">Home</a></li>
                        <li {% if title == "About" %}class="active"{% endif %}><a href="/about">About</a></li>
                        <li {% if title == "Contact" %}class="active"{% endif %}><a href="/contact">Contact</a></li>
                    </ul>
                    <div class="navbar-form navbar-right">
                        {% if request.user.is_authenticated %}
                            <!-- Split button -->
                            <div class="btn-group">
                                    <a href="/profile" class="btn btn-success"><i class="icon-user"></i> {{request.user.username | title}}</a>
                                    <button type="button" class="btn btn-success dropdown-toggle" data-toggle="dropdown">
                                    <span class="caret"></span>
                                </button>
                                <ul class="dropdown-menu" role="menu">
                                    <li><a href="/profile">Recent Activity</a></li>
                                    <li><a href="/profile/records">View Medical Records</a></li>
                                    <li><a href="/profile/edit">Edit Contact Info</a></li>
                                    <li class="divider"></li>
                                    <li><a href="/logout">Logout</a></li>
                                </ul>
                            </div>
                        {% else %}
                            <a href="/login" class="btn btn-success" type="submit"><i class="icon-user"></i> Sign in</a>
                        {% endif %}
                    </div>
                </div><!--/.nav-collapse -->
            </div>
        </div>
        {% if message %}
            <div class="alert alert-success sans" style="margin-bottom:0px;text-align:center;">
                <button type="button" class="close" data-dismiss="alert" aria-hidden="true">&times;</button>
                <i class="icon-check-sign"></i> {{message}}
            </div>
        {% endif %}
        {% block content %}{% endblock %}
        <script src="/static/js/jquery2.0.3.min.js" type="text/javascript"></script>
        <script src="/static/js/bootstrap.min.js" type="text/javascript"></script>
        {% block custom_scripts %}{% endblock %}
    </body>
</html>
